{% extends 'baykeshop/base_site.html' %}
{% load i18n baykeconfig %}

{% block main %}
<section class="bk-section">
    <div class="bk-container">
        <div class="bk-columns bk-is-centered">
            <div class="bk-column bk-is-5">
                <div class="bk-box p-6">
                    <div class="bk-has-text-centered">
                        <h1 class="bk-title bk-has-text-centered bk-has-text-grey-dark">
                            {% block auth_title %}{% translate title %}{% endblock %}
                        </h1>
                        {% dict_value 'SITE_TITLE' as SITE_TITLE %}
                        <p class="bk-subtitle">{% translate SITE_TITLE %}</p>
                    </div>
                    <div class="bk-dropdown-divider bk-has-background-light mb-4"></div>
                    <form action="" method="post">
                        {% csrf_token %}
                        {{ form.as_bulma }}
                        <input type="hidden" name="next" value="{{ next }}">
                        <div class="bk-field">
                            <button type="submit" class="bk-button bk-is-link bk-is-fullwidth">
                                <span class="bk-icon">
                                    <i class="mdi mdi-login-variant"></i>
                                </span>
                                <span>
                                    {% translate title %}
                                </span>
                            </button>
                        </div>
                        
                    </form>
                    {% block form_footer %}
                    <div class="bk-field mt-3">
                        <a href="{% url 'member:register' %}" class="bk-button bk-is-light bk-is-fullwidth">
                            <span class="bk-icon">
                                <i class="mdi mdi-account-plus"></i>
                            </span>
                            <span>
                                {% translate '注册账号' %}
                            </span>
                        </a>
                    </div>
                    <div class="bk-field mt-3">
                        <a href="{% url 'member:password_reset' %}" class="bk-button bk-is-light bk-is-fullwidth">
                            <span class="bk-icon">
                                <i class="mdi mdi-form-textbox-password"></i>
                            </span>
                            <span>
                                {% translate '忘记密码?' %}
                            </span>
                        </a>
                    </div>
                    {% endblock %}
                </div>
            </div>
        </div>
    </div>
</section>
{% endblock %}
    